feat(list_reservations): lock in expires_*/finalized_* window passthrough (0.4.3)#67
Merged
Conversation
…ough (0.4.3) Client-side companion to cycles-protocol-v0.yaml revision 2026-05-22 (runcycles/cycles-protocol#98) and runcycles/cycles-server#163. Closes the Python-client side of issue #162. The existing `list_reservations(**query_params: str)` signature already forwards arbitrary kwargs to the URL query string, so the four new ISO 8601 date-time params (expires_from / expires_to / finalized_from / finalized_to) work over the wire today without a code change. This commit adds sync + async regression tests that pin the contract — future tightening of the kwargs signature cannot drop the new params silently. Unlike `from` (a Python reserved keyword), the new param names are plain kwargs: client.list_reservations( tenant="acme", expires_from="2026-05-22T00:00:00Z", expires_to="2026-05-23T00:00:00Z", finalized_from="2026-05-15T00:00:00Z", finalized_to="2026-05-22T00:00:00Z", ) No protocol or wire-format change; servers older than v0.1.25.21 silently ignore the new params per the additive-parameter guarantee in cycles-protocol-v0.yaml. 393 tests pass at 100% coverage. Bumped to 0.4.3, updated AUDIT.md and CHANGELOG.md.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Client-side companion to cycles-protocol-v0.yaml revision 2026-05-22 and cycles-server#163 (the v0.1.25.21 release). Closes the Python-client side of runcycles/cycles-server#162. Follow-up to v0.4.2 (which shipped the
from/towindow) with the same shape, just four more params.What this PR does
list_reservationsconfirming the four new ISO-8601 window params are forwarded byte-exactly to the URL query string. The existing**query_params: strsignature already accepts them — the tests pin the contract.AUDIT.mdandCHANGELOG.md.No production code change.
Call-site syntax
Unlike
from(a Python reserved keyword that required dict-unpack**{"from": ...}in v0.4.2), the new param names are plain kwargs:Verification
pytest: 393 passed, 5 skipped.pytest --cov=runcycles: 100% coverage (gate ≥95% per CLAUDE.md).Test plan
Closes the Python-client side of the issue cluster for runcycles/cycles-server#162.